#pragma once
#include "CFGDataSource.h"
#include "CFGBaseConfig.h"
#include "CFGCodeManager.h"
#include "CFGMarketTime.h"
#include <Windows.h>

class CCFGConfig : public xml_api::Persistable
{
public:
  static CCFGConfig* Instance();

private:
  CCFGConfig(void);
  virtual ~CCFGConfig(void);

public:
  virtual bool SaveState(xml_api::Memento* m);
  virtual bool LoadState(xml_api::Memento* m);

public:
  CCFGDataSource m_data_source;
  CCFGBaseConfig m_base_config;
  CCFGCodeManager m_code_manager;
  CCFGMarketTime m_market_time;
  HMODULE m_main_module;

private:
  static CCFGConfig* m_ptr_instance;
};
